/******
 * waitpid.c - Simple wait usage
 *********/
#include <unistd.h>
#include <sys/types.h>
#include <sys/wait.h>
#include <stdio.h>
#include <stdlib.h>

#define FUNN aabb

typedef struct
{
  int a;
  int (*op)();
} lv0;
int op()
{
  printf("lv0 talk!\n");
  return 0;
}

typedef struct
{
  lv0 *super;
} lv1;
int op1()
{
  printf("lv1 talk!\n");
  return 0;
}
lv1 *new_lv1()
{
  lv1 *obj;
  obj->super->op = op1;
  return obj;
}

int main(void)
{
  lv1 *child = new_lv1();
  child->super->op();

  fflush(stdout);
  sleep(3);
  return 0;
}
